import request from '@/utils/request'
// 配置列表
export function getConfigList(query) {
  return request({
    url: '/config/getlist',
    method: 'get',
    params: query
  })
}

// 禁用
export function deleteConfig(query) {
  return request({
    url: '/config/delete',
    method: 'get',
    params: query
  })
}

// 启用
export function openConfig(query) {
  return request({
    url: '/config/open',
    method: 'get',
    params: query
  })
}

// 新增
export function addConfig(data) {
  return request({
    url: '/config/add',
    method: 'post',
    data: data
  })
}
// 编辑
export function editConfig(data) {
  return request({
    url: '/config/edit',
    method: 'post',
    data: data
  })
}

// 单位列表
export function getUnitList(query) {
  return request({
    url: '/unit/getlist',
    method: 'get',
    params: query
  })
}

// 新增单位
export function addUnit(data) {
  return request({
    url: '/unit/add',
    method: 'post',
    data: data
  })
}
// 编辑单位
export function editUnit(data) {
  return request({
    url: '/unit/edit',
    method: 'post',
    data: data
  })
}

// 删除单位
export function deleteUnit(query) {
  return request({
    url: '/unit/delete',
    method: 'get',
    params: query
  })
}

// 启用单位
export function openUnit(query) {
  return request({
    url: '/unit/open',
    method: 'get',
    params: query
  })
}


//类型列表
export function getMeetingTypeList(query) {
  return request({
    url: '/meeting/gettypelist',
    method: 'get',
    params: query
  })
}

// 新增类型
export function addMeeting(data) {
  return request({
    url: '/meeting/add',
    method: 'post',
    data: data
  })
}

// 编辑类型
export function editMeeting(data) {
  return request({
    url: '/meeting/edittype',
    method: 'post',
    data: data
  })
}
// 修改状态

export function edittypestatus(query) {
  return request({
    url: '/meeting/edittypestatus',
    method: 'get',
    params: query
  })
}

// 上传配置列表
export function getUploadList(query) {
  return request({
    url: '/fileupload/getlist',
    method: 'get',
    params: query
  })
}

// 通用上传接口
export function uploadfile(data) {
  return request({
    url: '/fileupload/uploadfile',
    method: 'post',
    data: data
  })
}

// 新增配置
export function addUpload(data) {
  return request({
    url: '/fileupload/add',
    method: 'post',
    data: data
  })
}

// 编辑配置
export function editUpload(data) {
  return request({
    url: '/fileupload/edit',
    method: 'post',
    data: data
  })
}

